package day16.udp的练习;

import java.io.IOException;
import java.net.*;

public class SendDemo {
    public static void main(String[] args) throws IOException {
        DatagramSocket ds=new DatagramSocket();
        byte[] bys="hallo,udp,我来了".getBytes();
        DatagramPacket ap=new DatagramPacket(bys,bys.length, InetAddress.getByName("192.168.23.127"),8888);
ds.send(ap);
ds.close();
    }
}
